<template>
	<view class="container">
		<view>
			<desc-wrapper :title="title" :desc="desc"></desc-wrapper>

			<z-card title="基本信息">
				<block v-if="resp">
					<view class="card-content-item">
						<text class="card-content-label_left ">您输入的数:</text>
						<text class="card-content_right card-text-red">{{ resp.data }}</text>
					</view>
					<view class="card-content-item">
						<text class="card-content-label_left ">吉凶:</text>
						<text class="card-content_right">{{resp.xiongji }}</text>
					</view>
					<view class="card-content-item">
						<text class="card-content-label_left ">数理:</text>
						<text class="card-content_right">{{resp.shuli}}</text>
					</view>
					<view class="card-content-item">
						<text class="card-content-label_left ">签语:</text>
						<text class="card-content_right">第{{resp.desc }}</text>
					</view>
				</block>

			</z-card>

			<view class="bottom-btns" style="transform: translateY(-100%);" @click="todashi">
				<view class="start-btn">
					<text>大师详解</text>
				</view>
			</view>
		</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				title: '数字测算结果',
				desc: '数字测算结果分析：心诚则灵，测算结果仅供参考。',
				resp: null
			}
		},

		onLoad(opt) {
			this.resp = JSON.parse(opt.params) //JSON字符串转换成JSON
		},
		methods:{
			todashi(){
				uni.switchTab({
					url:'/pages/tabbar/service'
				})
			}
		}
	}
</script>
<style lang="scss"></style>